home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
United Public Domain Gold 4
/
United Public Domain Gold 4.iso
/
fredfish
/
ff.0164.dms
/
ff.0164.adf
/
C-Functions
/
strinstr.c
< prev
next >
Wrap
C/C++ Source or Header
|
1988-11-22
|
324b
|
13 lines
#include <exec/types.h>
int strinstr (s,c) /* Check if character c is in string s */
UBYTE s[]; /* Return first pos if found, else NULL */
int c; /* Will return NULL if '\0' was searched for */
{
register int i=0;
while ( s[i] != c && s[i] ) i++;
return ( s[i] ? i+1 : NULL );
}